<template>
    <div class="house-content table-box">
        <ProTable ref="proTable" :requestApi="api.getList" :initData="false"
            :initParam="{ tableId: props.currentNode.id, source: 'personInfo' }" :columns="columns" :height="200" searchPosition="header">
            <template #content="scope">
                <div v-html="scope.row.content">
                </div>
            </template>
        </ProTable>
    </div>
</template>

<script setup lang="tsx" name="houseCompany">
import { ref, onMounted } from "vue";
import * as api from "/@/api/logger/operationLog";
import columnsFunction from './columns';
import ProTable from "/@/components/ProTable/index.vue";

const props = defineProps({
    currentNode: {
        type: Object,
        default: () => { }
    }
})

// 获取 ProTable 元素，调用其获取刷新数据方法（还能获取到当前查询参数，方便导出携带参数）
const proTable = ref()

// 获取表头信息
const columns = columnsFunction();

//初始化参数
// const initParam = reactive<any>({fid: props.currentNode.id})

onMounted(() => {
    proTable.value.refresh()
})
</script>

<style lang="scss" scoped>
:deep(.el-card__body) {
    padding: 12px;
}

:deep(.el-card__header) {
    padding: 10px 18px;
}

.house-content {
    padding: 24px;
    display: flex;
    flex-direction: column;
}
</style>